Skip to main content

Get trades

GET 

/bot-gateway-service/api/v3/myTrades

Get trades for a specific account and symbol based on the provided filters.

  • If fromId is set, it will get id >= that fromId. Otherwise, most recent orders are returned.
  • The time between startTime and endTime can't be longer than 24 hours.
  • If startTime and/or endTime are provided, then orderId is not required.

Request

Query Parameters

    Symbol string

    Symbol of the trading pair (e.g., XCBETH) (optional).

    Example: XCBETH
    OrderId int64

    The unique identifier of the order of type big integer generated by the Ping Exchange (optional).

    • If orderId is set, it will get trades for the specified orderId, Otherwise most recent orders are returned.
    Example: 5343
    StartTime int64

    The creation time of the trades should be greater than or equal StartTime (optional).

    • UTC timestamp in ms.
    • The time between startTime and endTime can't be longer than 24 hours.
    Example: 1643678921
    EndTime int64

    The creation time of the trades should be less than or equal EndTime (optional).

    • UTC timestamp in ms.
    • The time between startTime and endTime can't be longer than 24 hours.
    Example: 1643678921
    FromId int64

    Trade id to fetch from (optional).

    • Default gets most recent trades.
    Example: 654865
    Limit int32

    Maximum number of trades requested (optional).

    • Default 500; max 1000.
    Example: 500
    RecvWindow int64

    The number of milliseconds after timestamp the request is valid for (optional).

    • RecvWindow is optional.
    • The value cannot be greater than 60000.
    • If recvWindow is not sent, it defaults to 5000.
    Example: 60000

Responses

Success

Schema

  • Array [

  • symbol stringnullable

    Symbol of the trading pair (e.g., BTCUSDC).

    id int64

    The unique identifier of the trade.

    orderId int64

    The unique identifier of the order associated with the trade.

    orderListId int64

    The unique identifier of the order list associated with the trade.

    • Unless OCO, value will be -1
    price stringnullable

    The price at which the trade occurred.

    qty stringnullable

    The quantity of the asset traded.

    quoteQty stringnullable

    The quote quantity of the trade.

    commission stringnullable

    The commission paid for the trade.

    commissionAsset stringnullable

    The asset used for paying the commission.

    time int64

    The timestamp of the trade.

    isBuyer boolean

    Indicates if the trade was initiated by the buyer.

    isMaker boolean

    Indicates if the trade maker was the buyer.

    isBestMatch boolean

    Indicates if this trade is the best match.

  • ]

Loading...